]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
workspace: Split preparation steps from zoomFromOverview
authorGeorges Basile Stavracas Neto <georges.stavracas@gmail.com>
Fri, 1 Jan 2021 16:07:06 +0000 (13:07 -0300)
committerMarge Bot <marge-bot@gnome.org>
Wed, 3 Feb 2021 20:30:30 +0000 (20:30 +0000)
Next commit will bind the workspace state adjustment to the snap
adjustment in WorkspacesView, and we'll need the preparation
steps but not the easing of the state adjustment.

Split preparation steps from zoomFromOverview() into a new method
prepareToLeaveOverview().

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1613>

js/ui/workspace.js

index 8a9faf4ead3d14304e128701f50c8f1041fdb908..38218fc9bd3921027cb660d385ef5ebfece1436d 100644 (file)
@@ -1165,7 +1165,7 @@ class Workspace extends St.Widget {
         });
     }
 
-    zoomFromOverview() {
+    prepareToLeaveOverview() {
         for (let i = 0; i < this._windows.length; i++)
             this._windows[i].remove_all_transitions();
 
@@ -1176,6 +1176,10 @@ class Workspace extends St.Widget {
 
         this.layout_manager.layout_frozen = true;
         this._overviewHiddenId = Main.overview.connect('hidden', this._doneLeavingOverview.bind(this));
+    }
+
+    zoomFromOverview() {
+        this.prepareToLeaveOverview();
 
         if (this.metaWorkspace !== null && !this.metaWorkspace.active)
             return;